package com.lovestacks.tj.controller;

import com.lovestacks.tj.service.NewMediaOperationService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.HashMap;
import java.util.Map;

@Controller
@RequestMapping("/media")
public class FirstResponsiblePersonController {
    @Autowired
    private NewMediaOperationService newMediaOperationService;

//    @RequestMapping("savefrp")
//    @ResponseBody
//    public Map<String,Object> savefrp(String userId, int status, String name, String phone, String post, String personDepartment, String personEnterprise, String fileInfo){
//        try{
//            newMediaOperationService.genfrp( userId, status, name, phone, post, personDepartment, personEnterprise, fileInfo);
//            Map<String,Object> map = new HashMap<>();
//            map.put("code","success");
//            return map;
//        }catch (Exception e){
//            System.out.println(e.fillInStackTrace());
//            Map<String,Object> map = new HashMap<>();
//            map.put("code","fail");
//            map.put("msg",e.getMessage());
//            return map;
//        }
//    }

//    @RequestMapping("getfrp")
//    @ResponseBody
//    public Map<String,Object> getfrp(String userId){
//        try{
//            NewMediaAllKindInfo obj = firstResponsiblePersonService.getfrp(userId);
//            Map<String,Object> map = new HashMap<>();
//            map.put("code","success");
//            map.put("data",obj);
//            return map;
//        }catch (Exception e){
//            System.out.println(e.fillInStackTrace());
//            Map<String,Object> map = new HashMap<>();
//            map.put("code","fail");
//            map.put("msg",e.getMessage());
//            return map;
//        }
//    }


}
